package cn.xopencode.scoreservice.convert.demand;

import cn.xopencode.common.framework.vo.PageResult;
import cn.xopencode.score.api.rpc.demand.dto.ScoreReqDTO;
import cn.xopencode.score.api.rpc.demand.dto.ScoreRespDTO;
import cn.xopencode.scoreservice.dal.mysql.dataobject.demand.ScoreDO;
import com.baomidou.mybatisplus.core.metadata.IPage;
import org.mapstruct.Mapper;
import org.mapstruct.factory.Mappers;

import java.util.List;

@Mapper
public interface ScoreConvert {

    ScoreConvert INSTANCE = Mappers.getMapper(ScoreConvert.class);
    ScoreRespDTO convert(ScoreDO bean);
    PageResult<ScoreRespDTO> convertPage(IPage<ScoreDO> page);

    List<ScoreRespDTO> convertList(List<ScoreDO> list);

}
